//
//  VPCommentInputBar.h
//  vidpioneer
//
//  Created by pcyang on 15/7/29.
//  Copyright (c) 2015年 tencent. All rights reserved.
//

#import <UIKit/UIKit.h>

@class VPCommentInputBar;

typedef enum
{
    KeyBoardType_Has_Face = 1,
    KeyBoardType_Only_Symbol
}KeyBoardType;

@interface QLMomentTextView : UITextView<UIGestureRecognizerDelegate>

@property (nonatomic,assign) BOOL isHideCursorOrNot;
@property (nonatomic,assign) BOOL isSwitchingKeyBoardOrNot;

@end

@protocol VPCommentInputBarDelegate <NSObject>

@optional
- (BOOL)commentInputBarShouldBeginEditing:(VPCommentInputBar *)inputBar;
- (void)commentInputBarDidDismiss:(VPCommentInputBar *)inputBar;
- (void)commentInputBarDidPressEmojiButton:(VPCommentInputBar *)inputBar;
- (void)commentInputBarDidPressKeyBoardButton:(VPCommentInputBar *)inputBar;
- (void)commentInputBarDidPressSendButton:(VPCommentInputBar *)inputBar;
- (void)commentInputBar:(VPCommentInputBar *)inputBar textViewDidChange:(UITextView *)textView;

- (void)commentInputBarDidChangeHeight:(VPCommentInputBar *)inputBar;
@end

@interface VPCommentInputBar : UIView
@property(nonatomic,weak)id<VPCommentInputBarDelegate> delegate;
@property(nonatomic,assign)NSUInteger maxLength;

+ (VPCommentInputBar *)sharedInstance;

+(void)showInputBarAddedTo:(UIView*)view delegate:(id<VPCommentInputBarDelegate>)delegate placeHolderText:(NSString*)placeHolderText;
+(void)showInputBarAddedTo:(UIView*)view delegate:(id<VPCommentInputBarDelegate>)delegate text:(NSString*)text;
+ (void)dismiss;
+ (BOOL)isShowed;
+(void)clearText;

- (NSString *)getTextContent;
@end
